package cn.wolfcode.wolf2w.query;

import lombok.Getter;
import lombok.Setter;

import java.util.HashMap;
import java.util.Map;

/**
 * 用来封装一个map对象当做映射的,封装到这个类中
 */
@Getter
@Setter
public class TravelContdition {
    //定义一个空静态map
    public static final Map<Integer,TravelContdition > DAY_MAP= new HashMap<>();
    public static final Map<Integer,TravelContdition > PEREXPEND_MAP= new HashMap<>();
    //初始化参数
    static{
        //旅游天数初始化
        DAY_MAP.put(1,new TravelContdition(1,3));
        DAY_MAP.put(2,new TravelContdition(4,7));
        DAY_MAP.put(3,new TravelContdition(8,14));
        DAY_MAP.put(4,new TravelContdition(15,Integer.MAX_VALUE));

        //人均消费初始化
        PEREXPEND_MAP.put(1,new TravelContdition(1,999));
        PEREXPEND_MAP.put(2,new TravelContdition(1000,6000));
        PEREXPEND_MAP.put(3,new TravelContdition(6001,20000));
        PEREXPEND_MAP.put(4,new TravelContdition(20001,Integer.MAX_VALUE));
    }
    /**
     * 定义最大最小值
     *
     */
    private int min;
    private int max;
    //创建一个全参构造器
    public TravelContdition(int min,int max){
        this.min= min;
        this.max=max;
    }
}
